<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
  <style>
    * {
      margin: 0;
      padding: 0;
    }
    .flex {
      display: flex;
      flex-wrap: wrap;
      justify-content: space-around;
      width: 400px;
      height: 300px;
      margin: 100px auto;
      border: 1px solid #000;
    }
    .flex__item {
      margin-top: 10px;
      width: 80px;
      height: 80px;
      border: 1px solid greenyellow;
    }
    .flex__item:last-child{
      margin-right: auto;
      margin-left: 10px;
    }
  </style>
</head>
<body>
  <div class="flex">
    <div class="flex__item"></div>
    <div class="flex__item"></div>
    <div class="flex__item"></div>
    <div class="flex__item"></div>
    <div class="flex__item"></div>
    <div class="flex__item"></div>
    <div class="flex__item"></div>
    <div class="flex__item"></div>
    <div class="flex__item"></div>
  </div>
</body>
</html>